import Vue from 'vue'
import VueRouter from 'vue-router'
import Canvas from '../components/Canvas.vue'
import MatCanvas from "../components/MatCanvas.vue";
import BabylonJsCanvas from "../components/BabylonJsCanvas";


Vue.use(VueRouter)

const routes = [
    // {
    //     path: '/:id',
    //     component: Canvas
    //     // redirect: '/canvas/test',
    // },
    {
      path: '/MatCanvas',
      component: MatCanvas
    },
    {
      path: '/canvas/:id',//163216811522153194163501728958103225245149
      // path: '/canvas',
      name: 'Canvas',
      component: Canvas
    },
    {
      path: '/BabylonJsCanvas',
      component: BabylonJsCanvas
    }
]

let RouterMode = 'hash'
process.env.NODE_ENV === 'development' ? RouterMode = 'hash' : RouterMode = 'hash'

const router = new VueRouter({
    mode:RouterMode,
    routes
})

export default router
